package com.kkks.spring_rest.tick.model;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.MappedSuperclass;
import javax.persistence.OneToOne;
import javax.persistence.PrimaryKeyJoinColumn;

/**
 * AbstractWhoUserBaseInfo entity provides the base persistence definition of
 * the WhoUserBaseInfo entity. @author MyEclipse Persistence Tools
 */
@MappedSuperclass
public abstract class AbstractWhoUserBaseInfo implements java.io.Serializable {

	// Fields

	private Integer userId;
	private String userName;
	private String email;
	private Double userBalance;
	private Integer managerId;
	private String password;
	private Integer lastLogin;
	private Long lastIp;
	private Boolean isVip;
	private Integer payPoints;
	private Integer rankPoints;
	private Boolean userRank;
	private Integer regTime;
	private Long regIp;
	private Integer visitCount;
	private Integer lastPaymentId;
	private Integer lastShippingId;

	
//	private WhoUsers whoUsers;
//	
//	// Constructors
//	@OneToOne(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
//	@PrimaryKeyJoinColumn
//	public WhoUsers getWhoUsers() {
//		return whoUsers;
//	}
//
//	public void setWhoUsers(WhoUsers whoUsers) {
//		this.whoUsers = whoUsers;
//	}

	/** default constructor */
	public AbstractWhoUserBaseInfo() {
	}

	/** full constructor */
	public AbstractWhoUserBaseInfo(String userName, String email,
			Double userBalance, Integer managerId, String password,
			Integer lastLogin, Long lastIp, Boolean isVip, Integer payPoints,
			Integer rankPoints, Boolean userRank, Integer regTime, Long regIp,
			Integer visitCount, Integer lastPaymentId, Integer lastShippingId) {
		this.userName = userName;
		this.email = email;
		this.userBalance = userBalance;
		this.managerId = managerId;
		this.password = password;
		this.lastLogin = lastLogin;
		this.lastIp = lastIp;
		this.isVip = isVip;
		this.payPoints = payPoints;
		this.rankPoints = rankPoints;
		this.userRank = userRank;
		this.regTime = regTime;
		this.regIp = regIp;
		this.visitCount = visitCount;
		this.lastPaymentId = lastPaymentId;
		this.lastShippingId = lastShippingId;
	}

	// Property accessors
	@Id
	@GeneratedValue
	@Column(name = "user_id", unique = true, nullable = false)
	public Integer getUserId() {
		return this.userId;
	}

	public void setUserId(Integer userId) {
		this.userId = userId;
	}

	@Column(name = "user_name", nullable = false, length = 60)
	public String getUserName() {
		return this.userName;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

	@Column(name = "email", nullable = false, length = 60)
	public String getEmail() {
		return this.email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	@Column(name = "user_balance", nullable = false, precision = 10)
	public Double getUserBalance() {
		return this.userBalance;
	}

	public void setUserBalance(Double userBalance) {
		this.userBalance = userBalance;
	}

	@Column(name = "manager_id", nullable = false)
	public Integer getManagerId() {
		return this.managerId;
	}

	public void setManagerId(Integer managerId) {
		this.managerId = managerId;
	}

	@Column(name = "password", nullable = false, length = 32)
	public String getPassword() {
		return this.password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	@Column(name = "last_login", nullable = false)
	public Integer getLastLogin() {
		return this.lastLogin;
	}

	public void setLastLogin(Integer lastLogin) {
		this.lastLogin = lastLogin;
	}

	@Column(name = "last_ip", nullable = false)
	public Long getLastIp() {
		return this.lastIp;
	}

	public void setLastIp(Long lastIp) {
		this.lastIp = lastIp;
	}

	@Column(name = "is_vip", nullable = false)
	public Boolean getIsVip() {
		return this.isVip;
	}

	public void setIsVip(Boolean isVip) {
		this.isVip = isVip;
	}

	@Column(name = "pay_points", nullable = false)
	public Integer getPayPoints() {
		return this.payPoints;
	}

	public void setPayPoints(Integer payPoints) {
		this.payPoints = payPoints;
	}

	@Column(name = "rank_points", nullable = false)
	public Integer getRankPoints() {
		return this.rankPoints;
	}

	public void setRankPoints(Integer rankPoints) {
		this.rankPoints = rankPoints;
	}

	@Column(name = "user_rank", nullable = false)
	public Boolean getUserRank() {
		return this.userRank;
	}

	public void setUserRank(Boolean userRank) {
		this.userRank = userRank;
	}

	@Column(name = "reg_time", nullable = false)
	public Integer getRegTime() {
		return this.regTime;
	}

	public void setRegTime(Integer regTime) {
		this.regTime = regTime;
	}

	@Column(name = "reg_ip", nullable = false)
	public Long getRegIp() {
		return this.regIp;
	}

	public void setRegIp(Long regIp) {
		this.regIp = regIp;
	}

	@Column(name = "visit_count", nullable = false)
	public Integer getVisitCount() {
		return this.visitCount;
	}

	public void setVisitCount(Integer visitCount) {
		this.visitCount = visitCount;
	}

	@Column(name = "last_payment_id", nullable = false)
	public Integer getLastPaymentId() {
		return this.lastPaymentId;
	}

	public void setLastPaymentId(Integer lastPaymentId) {
		this.lastPaymentId = lastPaymentId;
	}

	@Column(name = "last_shipping_id", nullable = false)
	public Integer getLastShippingId() {
		return this.lastShippingId;
	}

	public void setLastShippingId(Integer lastShippingId) {
		this.lastShippingId = lastShippingId;
	}

}